NUT-Monitor: share one Python implementation across PyQt5 and PyQt6 - #3596
Open
user01010111 wants to merge 2 commits into
Open
NUT-Monitor: share one Python implementation across PyQt5 and PyQt6#3596user01010111 wants to merge 2 commits into
user01010111 wants to merge 2 commits into
Conversation
Generate the PyQt5 and PyQt6 commands from one Python 3 template while preserving their installed names and backend-specific behaviour. Let the dispatcher prefer PyQt6 by default and support NUT_MONITOR_QT=5 or NUT_MONITOR_QT=6 for explicit selection. Add focused dispatcher coverage and update the build recipes and documentation. Fix the existing authenticated automatic-reconnect callback to read its authentication widget through the parent interface. This prevents the unhandled timer callback exception that aborted both PyQt bindings. OpenAI Codex gpt-5.6-sol assisted with implementation and validation. The delegated worker used high reasoning. The human contributor reviewed and validated the change and remains responsible for it. Signed-off-by: user01010111 <lapses.50.booster@icloud.com>
|
A ZIP file with standard source tarball and another tarball with pre-built docs for commit ad33a49 is temporarily available: NUT-tarballs-PR-3596.zip. |
|
✅ Build nut 2.8.5.5156-master completed (commit bd15d205fd by @)
|
jimklimov
requested changes
Aug 31, 2026
jimklimov
left a comment
Member
There was a problem hiding this comment.
The simplification looks great, but maybe there is a bit more to it becoming perfect.
Name the shared Qt template variable consistently, document how configure generates the two legacy command names, and record version 2.2.0. Link the NEWS entry to PR networkupstools#3596. OpenAI Codex gpt-5.6-sol assisted with implementation and validation. The delegated worker used high reasoning. The human contributor reviewed and validated the change and remains responsible for it. Signed-off-by: user01010111 <lapses.50.booster@icloud.com>
|
✅ Build nut 2.8.5.5170-master completed (commit 49d2bc4077 by @)
|
|
✅ Build nut 2.8.5.5170-master completed (commit 49d2bc4077 by @) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #3589.
This replaces the separate PyQt5 and PyQt6 NUT-Monitor sources with one
shared Python 3 template. Autotools still generates the existing
NUT-Monitor-py3qt5andNUT-Monitor-py3qt6commands, so installedcommand and resource names remain unchanged.
The dispatcher continues to prefer PyQt6 and fall back to PyQt5. It now
also accepts
NUT_MONITOR_QT=5orNUT_MONITOR_QT=6when a particularbackend is required.
The shared reconnect path also corrects the existing authentication-widget
lookup. Both generated commands now recover an authenticated TLS connection
after the tested server-loss/restart sequence without the previous callback
exception and process abort.
The change adds focused dispatcher coverage and updates the build recipes,
manual page, configuration documentation, READMEs and NEWS entry.
Validation
git diff --check: passed.make distcheck-light SPELLCHECK_ERROR_FATAL=no: passed archive generation,extracted-tree configure/build/check, install/uninstall and re-dist.
preference and fallback, explicit Qt5/Qt6 selection, automatic Qt6
preference and invalid selection handling.
server, covering unauthenticated and authenticated connections, TLS 1.3,
tray and notification behaviour, favourite persistence, writable-variable
updates with server readback, and an authenticated instant command.
upsdand restarting it 1.2 seconds later, each command reconnected to theselected UPS, restored authenticated writable-variable access and resumed
TLS 1.3 without an exception or process abort.
passed.
Python 2/GTK2 runtime and native Windows/macOS validation were unavailable.
The Python 2 implementation and platform package-facing command names are
unchanged.
AI assistance
OpenAI Codex
gpt-5.6-solwas used by the controller and a delegatedhigh-reasoning implementation and validation worker. The human contributor
reviewed and validated the change and remains responsible for its content.